package com.ipcamera.demo.h5.view;

import android.os.Bundle;
import com.ipcamera.demo.h5.contract.BasePresenter;
import com.ipcamera.demo.h5.contract.BaseView;


public abstract class MVPBaseActivity<T extends BasePresenter> extends BaseActivity implements BaseView {

    public T mPresenter;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        if (mPresenter == null) {
            mPresenter = getPresenter();
        }
        super.onCreate(savedInstanceState);
    }

    protected abstract T getPresenter();
}
